var mongoose = require('mongoose');
var mongodb = require('../common/mongodb');
var Schema = mongoose.Schema;

var chatmessage = new mongoose.Schema({
    msgId:String,
    msgType:Number,
    readFlag:Number,
    content:String,
    senderId:String,
    receiverId:String,
    fileUrl:String,
    fileName:String,
    fileSize:Number,
    createTime:Date
});

var messageModel = mongodb.model('chatMessage',chatmessage,'chatMessage');
module.exports = messageModel;